emacs.git
21 months agoMerge remote-tracking branch 'origin/feature/which-key-in-core'
Philip Kaludercic [Tue, 18 Jun 2024 19:45:58 +0000 (21:45 +0200)]
Merge remote-tracking branch 'origin/feature/which-key-in-core'

21 months ago* lisp/org/ob-lua.el: Minor doc fixes.
Stefan Kangas [Tue, 18 Jun 2024 19:27:01 +0000 (21:27 +0200)]
* lisp/org/ob-lua.el: Minor doc fixes.

21 months agoUpdate Coccinelle URL
Stefan Kangas [Tue, 18 Jun 2024 19:10:42 +0000 (21:10 +0200)]
Update Coccinelle URL

* admin/coccinelle/README: Update URL.

21 months agoUpdate to Transient v0.7.0-1-g482bc777
Jonas Bernoulli [Tue, 18 Jun 2024 15:02:20 +0000 (17:02 +0200)]
Update to Transient v0.7.0-1-g482bc777

21 months agoAdapt tramp-use-file-attributes
Michael Albinus [Tue, 18 Jun 2024 12:40:20 +0000 (14:40 +0200)]
Adapt tramp-use-file-attributes

* doc/misc/tramp.texi: Fix indentation.
(Bug Reports): Mention Gmane group gmane.emacs.tramp.
(Frequently Asked Questions): Precise tramp-use-file-attributes entry.

* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Dump os-release when `tramp-verbose' is at least 9.

* lisp/net/tramp.el (tramp-use-file-attributes): Adapt docstring.
Use connection-local value.

21 months agoDisable usage of unicode for which-key by default
Philip Kaludercic [Tue, 18 Jun 2024 08:53:18 +0000 (10:53 +0200)]
Disable usage of unicode for which-key by default

* lisp/which-key.el (which-key-dont-use-unicode): Set to t.
(which-key-separator, which-key-ellipsis): Ensure that these
options are set after 'which-key-dont-use-unicode', as their
default value depends on it.

21 months agoRemove :underline from 'which-key-highlighted-command-face '
Philip Kaludercic [Tue, 18 Jun 2024 08:42:12 +0000 (10:42 +0200)]
Remove :underline from 'which-key-highlighted-command-face '

* lisp/which-key.el (which-key-highlighted-command-face): To
avoid using properties that might not be supported on all
displays, we instead inherit from the semantic face 'highlight'.

21 months ago; * lisp/which-key.el (which-key--process-page): Use ?\s
Philip Kaludercic [Tue, 18 Jun 2024 08:41:01 +0000 (10:41 +0200)]
; * lisp/which-key.el (which-key--process-page): Use ?\s

21 months agoPrevent which-key faces from over-extending during formatting
Philip Kaludercic [Tue, 18 Jun 2024 08:40:01 +0000 (10:40 +0200)]
Prevent which-key faces from over-extending during formatting

* lisp/which-key.el (which-key--pad-column): Instead of
injecting the description using a left-aligned format-string (%-[n]s),
we manually add the necessary padding so that the text
properties don't extend beyond the description.  This allows us
to use a face with a background without it extending until the
end of a column.

See also 63a6fb2a7a02ca88835c3fd473894d3b7d39ff15 for a similar
issue with Quick Help.

21 months agoFix window class of Android tooltips
Po Lu [Tue, 18 Jun 2024 07:53:18 +0000 (15:53 +0800)]
Fix window class of Android tooltips

* java/org/gnu/emacs/EmacsWindow.java (getWindowLayoutParams):
Declare as a panel, rather than an attached dialog.

21 months agoCorrect resolution of non-virtual directory names on Android
Po Lu [Tue, 18 Jun 2024 06:41:26 +0000 (14:41 +0800)]
Correct resolution of non-virtual directory names on Android

* src/androidvfs.c (android_vfs_canonicalize_name): Correct
return value in cases of underflowing the directory stack.
(android_unix_name): Reset vnode operations vector of copied
vnodes to their standard value, and exclude virtual directories
from subdirectories of the root directory's parent directory.
(android_root_name): Adjust to match.

21 months ago* java/Makefile.in (emacs.apk-in): Don't compress *.gz files on SDK 8.
Po Lu [Tue, 18 Jun 2024 02:11:51 +0000 (10:11 +0800)]
* java/Makefile.in (emacs.apk-in): Don't compress *.gz files on SDK 8.

21 months agodiff-mode: Optimize source language syntax highlighting
Dmitry Gutov [Mon, 17 Jun 2024 19:51:23 +0000 (22:51 +0300)]
diff-mode: Optimize source language syntax highlighting

* lisp/vc/diff-mode.el (diff--get-revision-properties):
Never pass FILE to 'diff-syntax-fontify-props'; assume that
'vc-find-revision-no-save' has called the major mode function
already (bug#71604).

21 months ago* lisp/tab-line.el (tab-line-force-update): New function (bug#71601).
Juri Linkov [Mon, 17 Jun 2024 16:47:53 +0000 (19:47 +0300)]
* lisp/tab-line.el (tab-line-force-update): New function (bug#71601).

(tab-line-tab-name-function, tab-line-tabs-function)
(tab-line-tabs-buffer-group-function)
(tab-line-tabs-buffer-group-sort-function)
(tab-line-tabs-buffer-groups-sort-function)
(tab-line-tab-name-format-function):
Use 'tab-line-force-update' in the :set lambda of defcustom.
(tab-line-tab-name-function, tab-line-tabs-function)
(tab-line-cache-key-function): Mention 'tab-line-force-update'
in the docstring.
(tab-line-new-button-show, tab-line-close-button-show):
In the :set lambda of defcustom use 'force-mode-line-update'
with the non-nil arg ALL.

21 months ago* lisp/outline.el: Make revert-related functions internal.
Juri Linkov [Mon, 17 Jun 2024 16:40:00 +0000 (19:40 +0300)]
* lisp/outline.el: Make revert-related functions internal.

(outline--hidden-headings-paths)
(outline--hidden-headings-restore-paths): Rename with the prefix
'outline--' to mark them internal to discourage from relying on
their arguments and return values.

21 months ago(bookmark--jump-via): Ensure 'window-point' is set correctly
Eshel Yaron [Mon, 17 Jun 2024 14:48:43 +0000 (16:48 +0200)]
(bookmark--jump-via): Ensure 'window-point' is set correctly

* lisp/bookmark.el (bookmark--jump-via): Record
bookmark-prescribed point before calling DISPLAY-FUNCTION, and
use it to set 'window-point' afterwards.  (Bug#71603)

21 months ago* lisp/touch-screen.el (touch-screen-inhibit-drag): Fix 'not' arity use.
Andrea Corallo [Mon, 17 Jun 2024 13:38:37 +0000 (15:38 +0200)]
* lisp/touch-screen.el (touch-screen-inhibit-drag): Fix 'not' arity use.

21 months agoDon't hide `not` and `null` arity errors
Mattias Engdegård [Mon, 17 Jun 2024 11:14:08 +0000 (13:14 +0200)]
Don't hide `not` and `null` arity errors

* lisp/emacs-lisp/byte-opt.el (byte-optimize-not):
Don't silently convert incorrect `not` and `null` applications to nil.

21 months ago; Auto-commit of loaddefs files.
Po Lu [Mon, 17 Jun 2024 09:45:41 +0000 (17:45 +0800)]
; Auto-commit of loaddefs files.

21 months agoReinforce bitmap reconfiguration on Android
Po Lu [Mon, 17 Jun 2024 09:43:24 +0000 (17:43 +0800)]
Reinforce bitmap reconfiguration on Android

* java/org/gnu/emacs/EmacsView.java (EmacsView) <unswapped>: New
field in which to record whether the back buffer has received
contents beyond those present at the last buffer swap.
<dimensionsLock>: Delete field.
(onAttachedToWindow, onLayout, handleDirtyBitmap)
(prepareForLayout): Rather, synchronize window dimensions with
the view.
(getCanvas, getBitmap): Do not reconfigure the back buffer
bitmap if such outstanding data exists.
(postSwapBuffers): New function.
(swapBuffers): If such outstanding data exists and the back
bufferis pending reconfiguration, recreate the back buffer and
report exposure.

* src/androidterm.c (handle_one_android_event): Fix indentation.

21 months agoImprove treatment of touch screen input by rmc and its callers
Po Lu [Mon, 17 Jun 2024 04:11:25 +0000 (12:11 +0800)]
Improve treatment of touch screen input by rmc and its callers

* lisp/emacs-lisp/rmc.el (read-multiple-choice--short-answers):
Run touch screen event translation on touch screen events
received, and respond to pinch, tap and scrolling gestures.

* lisp/net/nsm.el (nsm-query-user): Disable use-dialog-box in
the details window.

* lisp/touch-screen.el (touch-screen-translate-touch): Autoload.

21 months ago* lisp/outline.el: Keep point on the same outline after revert.
Juri Linkov [Mon, 17 Jun 2024 06:32:45 +0000 (09:32 +0300)]
* lisp/outline.el: Keep point on the same outline after revert.

(outline-hidden-headings-paths): Return the current path as well.
(outline-hidden-headings-restore-paths): Move point to the path
that was current before reverting the buffer (bug#71466).
(outline-revert-buffer-restore-visibility):
Handle both values returned from outline-hidden-headings-paths.

21 months ago; Translate comment to English
Stefan Kangas [Sun, 16 Jun 2024 20:16:36 +0000 (22:16 +0200)]
; Translate comment to English

* lisp/progmodes/php-ts-mode.el
(php-ts-mode--parent-html-heuristic): Translate comment to English.

21 months ago; Fix typos
Stefan Kangas [Sun, 16 Jun 2024 19:59:42 +0000 (21:59 +0200)]
; Fix typos

21 months agoTramp: handle non-standard file system like GPFS
Michael Albinus [Sun, 16 Jun 2024 14:03:41 +0000 (16:03 +0200)]
Tramp: handle non-standard file system like GPFS

* doc/misc/tramp.texi (Frequently Asked Questions):
Explain tramp-use-file-attributes.

* lisp/net/tramp.el (tramp-use-file-attributes): New defcustom and
defsubst.
(tramp-skeleton-file-exists-p):
* lisp/net/tramp-adb.el (tramp-adb-handle-file-executable-p)
(tramp-adb-handle-file-readable-p):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-file-executable-p)
(tramp-sudoedit-handle-file-readable-p)
(tramp-sudoedit-handle-file-writable-p): Use it.
* lisp/net/tramp-sh.el (tramp-sh-handle-file-executable-p)
(tramp-sh-handle-file-readable-p)
(tramp-sh-handle-file-writable-p): Use it.
(tramp-sh-handle-set-file-acl): Fix property name.

21 months agoFix clipboard request on macOS for yank-media
Robert Pluim [Sun, 16 Jun 2024 12:23:37 +0000 (14:23 +0200)]
Fix clipboard request on macOS for yank-media

'yank-media' makes a request with 'CLIPBOARD and 'TARGETS, which on
other platforms returns the type(s) of the current selection, but on
macOS returned the selection itself.  Make it return the types instead.

This fixes (Bug#71377).

* src/nsselect.m (ns_get_local_selection): Return nil when called with
QCLIPBOARD and QTARGETS, so that 'ns_get_foreign_selection' is called to
return the type(s) of the selection.

21 months ago; Fix more checkdoc warnings in which-key.el
Stefan Kangas [Sun, 16 Jun 2024 11:39:26 +0000 (13:39 +0200)]
; Fix more checkdoc warnings in which-key.el

* lisp/which-key.el (which-key-special-keys)
(which-key-highlighted-command-face, which-key--safe-lookup-key)
(which-key--safe-lookup-key-description)
(which-key-add-keymap-based-replacements)
(which-key-add-key-based-replacements)
(which-key--fit-buffer-to-window-horizontally)
(which-key--popup-max-dimensions)
(which-key--propertize-description, which-key--format-and-replace)
(which-key--get-bindings, which-key--list-to-pages)
(which-key--create-pages-1, which-key--create-pages)
(which-key--get-popup-map, which-key-show-major-mode): Fix
checkdoc warnings.

21 months agoMinor adjustments to battery.el on Android
Po Lu [Sun, 16 Jun 2024 07:27:43 +0000 (15:27 +0800)]
Minor adjustments to battery.el on Android

* src/android.c (android_query_battery):

* java/org/gnu/emacs/EmacsService.java (queryBattery19)
(queryBattery): Reorder items in value for consistency with
Fandroid_query_battery.

* lisp/battery.el (battery-status-function): Select
battery-android only when android-query-battery is present.
(battery-android): Return temperature and correct values of
power source constants.

21 months agoFix Eshell "which" test on MS-Windows
Jim Porter [Sat, 15 Jun 2024 23:59:11 +0000 (16:59 -0700)]
Fix Eshell "which" test on MS-Windows

* test/lisp/eshell/esh-cmd-tests.el
(esh-cmd-test/which/plain/external-program): Compare the file name
case-insensitively on case-insensitive file systems.

* test/lisp/eshell/eshell-tests-helpers.el
(eshell-command-result--equal): Revert to the previous implementation.

21 months agoSimplify bitmap reallocation on Android
Po Lu [Sun, 16 Jun 2024 03:35:44 +0000 (11:35 +0800)]
Simplify bitmap reallocation on Android

* java/org/gnu/emacs/EmacsView.java: Update outdated commentary.
(handleDirtyBitmap): Don't copy contents of the previous bitmap
to the new.
(onLayout): Unconditionally expose upon layout changes.

21 months agoDocument unavailability of color fonts on Android
Po Lu [Sun, 16 Jun 2024 02:55:43 +0000 (10:55 +0800)]
Document unavailability of color fonts on Android

* doc/emacs/android.texi (Android Fonts): Document absence of
support for color fonts.

21 months agoAccount for duplicate removal on restoring eww-history-position
James Thomas [Mon, 10 Jun 2024 21:30:33 +0000 (03:00 +0530)]
Account for duplicate removal on restoring eww-history-position

* lisp/net/eww.el (eww-desktop-misc-data): Add :history-position
(eww-restore-desktop): Use it.
(desktop-locals-to-save): Remove the raw variable.

21 months agoFix :version tag for 'which-key' custom data
Philip Kaludercic [Sat, 15 Jun 2024 19:24:46 +0000 (21:24 +0200)]
Fix :version tag for 'which-key' custom data

* lisp/which-key.el (which-key-idle-delay)
(which-key-idle-secondary-delay, which-key-echo-keystrokes)
(which-key-max-description-length)
(which-key-min-column-description-width)
(which-key-add-column-padding, which-key-unicode-correction)
(which-key-dont-use-unicode, which-key-separator)
(which-key-ellipsis, which-key-prefix-prefix)
(which-key-compute-remaps, which-key-replacement-alist)
(which-key-allow-multiple-replacements)
(which-key-show-docstrings, which-key-highlighted-command-list)
(which-key-special-keys, which-key-buffer-name)
(which-key-show-prefix, which-key-popup-type)
(which-key-min-display-lines, which-key-max-display-columns)
(which-key-side-window-location, which-key-side-window-slot)
(which-key-side-window-max-width)
(which-key-side-window-max-height, which-key-frame-max-width)
(which-key-frame-max-height)
(which-key-allow-imprecise-window-fit)
(which-key-show-remaining-keys, which-key-sort-order)
(which-key-sort-uppercase-first, which-key-paging-prefixes)
(which-key-paging-key, which-key-use-C-h-commands)
(which-key-show-early-on-C-h, which-key-is-verbose)
(which-key-preserve-window-configuration)
(which-key-hide-alt-key-translations, which-key-delay-functions)
(which-key-allow-regexps, which-key-inhibit-regexps)
(which-key-show-transient-maps, which-key-init-buffer-hook)
(which-key-key-face, which-key-separator-face)
(which-key-note-face, which-key-command-description-face)
(which-key-local-map-description-face)
(which-key-highlighted-command-face)
(which-key-group-description-face, which-key-special-key-face)
(which-key-docstring-face)
(which-key-custom-popup-max-dimensions-function)
(which-key-custom-hide-popup-function)
(which-key-custom-show-popup-function, which-key-lighter)
(which-key-inhibit-display-hook)
(which-key-this-command-keys-function)
(which-key-allow-evil-operators)
(which-key-show-operator-state-maps): Rename :version to
:package-version and add new :version tags indicating that
'which-key' was added with Emacs 30.

21 months agoFix em-extpipe-tests on MS-Windows
Eli Zaretskii [Sat, 15 Jun 2024 19:20:56 +0000 (22:20 +0300)]
Fix em-extpipe-tests on MS-Windows

* test/lisp/eshell/em-extpipe-tests.el (em-extpipe-test-14): Fix
test on MS-Windows (bug#71446).

21 months agoFix 'wrong-type-argument' in 'php-ts-mode--webserver-read-args'
Vincenzo Pupillo [Sat, 15 Jun 2024 16:57:29 +0000 (18:57 +0200)]
Fix 'wrong-type-argument' in 'php-ts-mode--webserver-read-args'

Prevents php-ts-mode--webserver-read-args from throwing an
error if the current buffer is not associated with a file.
* lisp/progmodes/php-ts-mode.el (php-ts-mode--webserver-read-args):
Use 'default-directory if' the current buffer is not associated
with a file.  (Bug#71574)
(php-ts-mode-run-php-webserver): Fix doc string.

21 months agoUpdate to Org 9.7.4-7-g165319
Kyle Meyer [Sat, 15 Jun 2024 18:25:35 +0000 (14:25 -0400)]
Update to Org 9.7.4-7-g165319

21 months ago; Improve last change
Jim Porter [Sat, 15 Jun 2024 18:27:07 +0000 (11:27 -0700)]
; Improve last change

* test/lisp/eshell/esh-proc-tests.el (esh-proc-test/kill-pipeline): Fix
check of exit message and ensure we have only one prompt.

21 months ago; Add command logging to some more Eshell tests
Jim Porter [Sat, 15 Jun 2024 18:06:58 +0000 (11:06 -0700)]
; Add command logging to some more Eshell tests

* test/lisp/eshell/esh-proc-tests.el (esh-proc-test/kill-pipeline)
(esh-proc-test/kill-pipeline-head): Write debug logs on failure.

21 months agoMerge from origin/emacs-29
Eli Zaretskii [Sat, 15 Jun 2024 17:06:09 +0000 (13:06 -0400)]
Merge from origin/emacs-29

59261e6f4fe Fix auth-info-password
778f8c793d1 ; * lisp/mail/rmail.el (rmail-get-new-mail-hook): Doc fix.
e6044b29e65 ; Minor fixes in ELisp manual

21 months agoAvoid byte-compilation warnings in php-ts-mode
Eli Zaretskii [Sat, 15 Jun 2024 17:03:39 +0000 (20:03 +0300)]
Avoid byte-compilation warnings in php-ts-mode

* lisp/progmodes/php-ts-mode.el (treesit-search-forward)
(treesit-node-prev-sibling, treesit-node-first-child-for-pos):
Declare.

21 months agoHonor 'Info-additional-directory-list' in 'C-h R' completion
Eshel Yaron [Sat, 15 Jun 2024 16:48:34 +0000 (18:48 +0200)]
Honor 'Info-additional-directory-list' in 'C-h R' completion

* lisp/info.el (info--manual-names): Take into account
'Info-additional-directory-list', in addition to
'Info-directory-list'.  (Bug#71368)

21 months ago; * doc/emacs/package.texi (Package Files): Fix wording.
Eli Zaretskii [Sat, 15 Jun 2024 16:47:44 +0000 (19:47 +0300)]
; * doc/emacs/package.texi (Package Files): Fix wording.

21 months agoBump `which-key` minimum Emacs version to 25.1
Stefan Kangas [Sat, 15 Jun 2024 14:31:14 +0000 (16:31 +0200)]
Bump `which-key` minimum Emacs version to 25.1

* lisp/which-key.el: Bump minimum required Emacs version to 25.1 since
the package depends on `universal-argument--description'.  This was
detected by package-lint.

21 months agoFix checkdoc warnings in which-key.el
Stefan Kangas [Sat, 15 Jun 2024 14:29:36 +0000 (16:29 +0200)]
Fix checkdoc warnings in which-key.el

* lisp/which-key.el (which-key, which-key-idle-secondary-delay)
(which-key-replacement-alist)
(which-key-allow-multiple-replacements, which-key-show-docstrings)
(which-key-highlighted-command-list, which-key-show-prefix)
(which-key-sort-order, which-key-sort-uppercase-first)
(which-key-use-C-h-commands, which-key-show-early-on-C-h)
(which-key-preserve-window-configuration, which-key-C-h-map)
(which-key-delay-functions, which-key-inhibit-regexps)
(which-key-faces, which-key-key-face, which-key-separator-face)
(which-key-note-face, which-key-command-description-face)
(which-key-local-map-description-face, which-key-special-key-face)
(which-key-inhibit-display-hook)
(which-key-this-command-keys-function, which-key-mode)
(which-key--init-buffer, which-key--get-menu-item-binding)
(which-key--get-keymap-bindings, which-key-reload-key-sequence)
(which-key-show-major-mode, which-key-show-full-major-mode)
(which-key-C-h-dispatch): Fix checkdoc warnings.

21 months agoFix problem with recently-added defcustom's
Eli Zaretskii [Sat, 15 Jun 2024 13:20:01 +0000 (16:20 +0300)]
Fix problem with recently-added defcustom's

* lisp/progmodes/php-ts-mode.el (php-ts-mode-php-config)
(php-ts-mode-ws-port, php-ts-mode-ws-document-root)
(php-ts-mode-ws-workers): Fix :type and :safe attributes.
(Bug#71566)

21 months agoBetter documentation of 'emacs-internal' encoding
Eli Zaretskii [Sat, 15 Jun 2024 12:59:55 +0000 (15:59 +0300)]
Better documentation of 'emacs-internal' encoding

* doc/lispref/nonascii.texi (Coding System Basics): Recommend
'emacs-internal' encoding for caching.

21 months ago* etc/NEWS: Mention the addition of 'which-key'
Philip Kaludercic [Sat, 15 Jun 2024 12:55:20 +0000 (14:55 +0200)]
* etc/NEWS: Mention the addition of 'which-key'

21 months ago* lisp/which-key.el: Clean up file header
Philip Kaludercic [Sat, 15 Jun 2024 12:48:58 +0000 (14:48 +0200)]
* lisp/which-key.el: Clean up file header

21 months agoMerge remote-tracking branch 'github-which-key/master'
Philip Kaludercic [Sat, 15 Jun 2024 12:44:06 +0000 (14:44 +0200)]
Merge remote-tracking branch 'github-which-key/master'

21 months ago; * lisp/textmodes/ispell.el (ispell-aspell-find-dictionary): Doc fix.
Eli Zaretskii [Sat, 15 Jun 2024 12:02:11 +0000 (15:02 +0300)]
; * lisp/textmodes/ispell.el (ispell-aspell-find-dictionary): Doc fix.

21 months ago; Fix some docstrings. (bug#71532)
Arash Esbati [Thu, 13 Jun 2024 09:46:09 +0000 (11:46 +0200)]
; Fix some docstrings. (bug#71532)

21 months agoFix doc strings in ispell.el
Eli Zaretskii [Sat, 15 Jun 2024 11:55:31 +0000 (14:55 +0300)]
Fix doc strings in ispell.el

* lisp/textmodes/ispell.el (ispell-check-version)
(ispell-get-casechars, ispell-get-not-casechars)
(ispell-get-otherchars, ispell-get-many-otherchars-p)
(ispell-get-ispell-args, ispell-get-extended-character-mode)
(ispell-get-coding-system, ispell-word, ispell-get-word)
(ispell-pdict-save, ispell-command-loop, ispell-help)
(ispell-filter, ispell-highlight-spelling-error)
(ispell-change-dictionary, ispell-region, ispell-ignore-fcc)
(ispell-get-line, ispell-message): Doc fixes (bug#71532)

21 months agoFix calc-trail-here for first line of trail.
Ashwin Kafle [Thu, 13 Jun 2024 10:21:38 +0000 (16:06 +0545)]
Fix calc-trail-here for first line of trail.

* lisp/calc/calc.el(calc-trail-here): Change 'or' to 'and'
since (bobp) can return true even if the buffer is not empty.
(Bug#71533)

21 months agoAllow escape sequences in Python prompts
kobarity [Tue, 11 Jun 2024 16:09:21 +0000 (01:09 +0900)]
Allow escape sequences in Python prompts

* lisp/progmodes/python.el (python-shell-prompt-detect): Use
Python's json package if available, and remove escape sequences
in prompts.
* test/lisp/progmodes/python-tests.el
(python-tests-interpreter-2-6-higher-p): New predicate
function.
(python-shell-prompt-detect-7): New test.  (Bug#71440)

21 months agoFix 'reindent-then-newline-and-indent' with 'abbrev-mode'
Eli Zaretskii [Sat, 15 Jun 2024 10:04:12 +0000 (13:04 +0300)]
Fix 'reindent-then-newline-and-indent' with 'abbrev-mode'

* lisp/simple.el (reindent-then-newline-and-indent): Use a marker
for the initial position.  (Bug#71459)

21 months agoPrevent deletion of separator in *edit string* buffer
Eli Zaretskii [Sat, 15 Jun 2024 08:37:34 +0000 (11:37 +0300)]
Prevent deletion of separator in *edit string* buffer

* lisp/textmodes/string-edit.el (string-edit): Make the separator
line read-only.  (Bug#71405)

21 months agoFix electric-pair-mode when characters are bound to non-ASCII keys
Eli Zaretskii [Sat, 15 Jun 2024 08:08:22 +0000 (11:08 +0300)]
Fix electric-pair-mode when characters are bound to non-ASCII keys

* src/cmds.c (Fself_insert_command): Record the argument C in
'last-command-event'.  (Bug#71337)

21 months ago; * nt/README.W32: Remove Windows 95.
Eli Zaretskii [Sat, 15 Jun 2024 07:00:59 +0000 (10:00 +0300)]
; * nt/README.W32: Remove Windows 95.

21 months ago; * nt/README: Remove Windows 95.
Eli Zaretskii [Sat, 15 Jun 2024 06:59:55 +0000 (09:59 +0300)]
; * nt/README: Remove Windows 95.

21 months agoSend proper substitution character to Android IMEs
Po Lu [Sat, 15 Jun 2024 02:04:07 +0000 (10:04 +0800)]
Send proper substitution character to Android IMEs

* src/androidterm.c (android_text_to_string): Substitute
REPLACEMENT CHARACTER for NULL in converting characters not
representable without surrogate pairs to UTF-16.

21 months agotypescript/tsx-ts-mode: Indentation for type parameters
Arsen Arsenović [Fri, 14 Jun 2024 23:18:56 +0000 (02:18 +0300)]
typescript/tsx-ts-mode: Indentation for type parameters

* lisp/progmodes/typescript-ts-mode.el
(typescript-ts-mode--indent-rules): Add rule for type_parameters.

21 months ago; * src/insdel.c (insert_from_gap_1): Update commentary.
Eli Zaretskii [Fri, 14 Jun 2024 18:44:56 +0000 (21:44 +0300)]
; * src/insdel.c (insert_from_gap_1): Update commentary.

21 months ago; Update comments in a recent commit
Eli Zaretskii [Fri, 14 Jun 2024 18:42:18 +0000 (21:42 +0300)]
; Update comments in a recent commit

* src/process.c (read_and_insert_process_output):
* src/insdel.c (insert_from_gap):
* src/coding.h (struct coding_system): Improve comments (bug#71525).

21 months ago; Fix Icomplete error during candidate highlighting
Eshel Yaron [Fri, 14 Jun 2024 17:49:21 +0000 (19:49 +0200)]
; Fix Icomplete error during candidate highlighting

* lisp/icomplete.el (icomplete-completions): Pass completion
candidates through 'completion-lazy-hilit' before trimming
common prefix, rather than after.

https://lists.gnu.org/archive/html/emacs-devel/2024-06/msg00271.html

21 months ago"Insert before markers" in read_and_insert_process_output properly
Dmitry Gutov [Fri, 14 Jun 2024 16:50:59 +0000 (19:50 +0300)]
"Insert before markers" in read_and_insert_process_output properly

* src/coding.c (setup_coding_system): Initialize it.
(produce_chars, encode_coding, decode_coding_gap):
Obey it in insert_from_gap calls.
(encode_string_utf_8, decode_string_utf_8): Update the other calls
to insert_from_gap to have one new argument (false).

* src/coding.h: New field insert_before_markers.

* src/decompress.c (Fzlib_decompress_region): Here too.

* src/insdel.c (insert_from_gap):
Accept new argument BEFORE_MARKERS (bug#71525) and pass it through
to adjust_markers_for_insert.

* src/lisp.h: Update prototype.

* src/process.c (read_and_insert_process_output):
Set process_coding->insert_before_markers instead of calling
adjust_markers_for_insert.

21 months ago* lisp/progmodes/project.el: Bump the version
Dmitry Gutov [Fri, 14 Jun 2024 15:24:04 +0000 (18:24 +0300)]
* lisp/progmodes/project.el: Bump the version

21 months agoFix generation of org.texi from org.org
Eli Zaretskii [Fri, 14 Jun 2024 11:38:01 +0000 (14:38 +0300)]
Fix generation of org.texi from org.org

* doc/misc/Makefile.in (org_template): Bind
'org-id-track-globally' to nil when running
'org-texinfo-export-to-texinfo-batch', to avoid searching local
user files when building the Org manual.

21 months agoCorrect last change
Po Lu [Fri, 14 Jun 2024 08:42:32 +0000 (16:42 +0800)]
Correct last change

* lisp/term.el (term-generate-db-directory): Don't delete
DST-DIRECTORY if not yet existent.

21 months agoPort term.el's terminfo machinery to Android
Po Lu [Fri, 14 Jun 2024 08:21:55 +0000 (16:21 +0800)]
Port term.el's terminfo machinery to Android

* lisp/term.el (term-generate-db-directory): New function.  Copy
/assets/etc/e to the cache directory, on Android, and return the
same.
(term-exec-1): Call term-generate-db-directory in place of
data-directory.

21 months agoUnconditionally prefer built-in decompression functions on Android
Po Lu [Fri, 14 Jun 2024 07:11:04 +0000 (15:11 +0800)]
Unconditionally prefer built-in decompression functions on Android

* lisp/jka-compr.el (jka-compr-insert-file-contents): Prefer
built-in decompression functions (i.e., zlib) to external
agents.

21 months ago; * lisp/eshell/em-script.el (eshell-execute-file): Improve docstring.
Jim Porter [Fri, 14 Jun 2024 04:44:40 +0000 (21:44 -0700)]
; * lisp/eshell/em-script.el (eshell-execute-file): Improve docstring.

21 months agoRestore file's original name after a failed rename_replace on Windows 9X
Po Lu [Fri, 14 Jun 2024 02:44:20 +0000 (10:44 +0800)]
Restore file's original name after a failed rename_replace on Windows 9X

* src/w32.c (sys_rename_replace): If the rename operation fails
and an intermediate name was generated and applied to the input
file, restore the original.

21 months agoEnable compiling Emacs with implicit Make rules suppressed
Po Lu [Fri, 14 Jun 2024 01:58:04 +0000 (09:58 +0800)]
Enable compiling Emacs with implicit Make rules suppressed

* lib/Makefile.in (.SUFFIXES):

* lwlib/Makefile.in (.SUFFIXES):

* oldXMenu/Makefile.in (.SUFFIXES):

* src/Makefile.in (.SUFFIXES): Register .c as a default suffix,
for this list is emptied when `-r' is provided to Make.

21 months agoFix file listing in submodules with project-files-relative-names=t
Pär Bohrarper [Fri, 14 Jun 2024 01:04:20 +0000 (04:04 +0300)]
Fix file listing in submodules with project-files-relative-names=t

* lisp/progmodes/project.el (project--vc-list-files):
Prepend module names to files when project-files-relative-names is
non-nil (bug#71538).

21 months ago; Minor editorial fixes to some Eshell tests
Jim Porter [Thu, 13 Jun 2024 19:22:01 +0000 (12:22 -0700)]
; Minor editorial fixes to some Eshell tests

* test/lisp/eshell/esh-proc-tests.el
(esh-proc-test/kill-process/redirect-message): Move next to its sibling
tests.
(esh-proc-test/remote/remote-path): Rename from 'esh-var-test/...'.

21 months ago; (completion-basic-all-completions): Fix recent change
Eshel Yaron [Thu, 13 Jun 2024 14:43:41 +0000 (16:43 +0200)]
; (completion-basic-all-completions): Fix recent change

* lisp/minibuffer.el (completion-basic-all-completions): Don't
omit base size.

https://lists.gnu.org/archive/html/emacs-devel/2024-06/msg00235.html

21 months ago;cperl-mode.el: Avoid false positives when parsing new Perl syntax
Harald Jörg [Thu, 13 Jun 2024 12:34:16 +0000 (14:34 +0200)]
;cperl-mode.el: Avoid false positives when parsing new Perl syntax

* lisp/progmodes/cperl-mode.el (cperl--package-for-imenu-rx)
(cperl--class-for-imenu-rx): avoid false positives when collecting
imenu entries
* lisp/progmodes/cperl-mode.el (cperl-init-faces): avoid false
positives when detecting package names

* test/lisp/progmodes/cperl-mode-tests.el
(cperl-test-imenu-index): Add test verifying that $class_false is
not shown as a class _false

* test/lisp/progmodes/cperl-mode-resources/grammar.pl: Add a line
containing a false positive "$class_false"

21 months ago; * src/androidterm.c (android_term_init): Typo.
Po Lu [Thu, 13 Jun 2024 12:11:43 +0000 (20:11 +0800)]
; * src/androidterm.c (android_term_init): Typo.

21 months agophp-ts-mode: minor fixes
Mattias Engdegård [Thu, 13 Jun 2024 08:49:28 +0000 (10:49 +0200)]
php-ts-mode: minor fixes

* lisp/progmodes/php-ts-mode.el (php-ts-mode-flymake-php):
Don't use `any` to mean `not-newline`; it's misleading.
(php-ts-mode--predefined-constant): Remove duplicate "E_USER_NOTICE".

21 months ago; * src/w32proc.c (sys_kill): Handle negative PID when sig == 0.
Eli Zaretskii [Thu, 13 Jun 2024 08:03:52 +0000 (11:03 +0300)]
; * src/w32proc.c (sys_kill): Handle negative PID when sig == 0.

21 months agoAdapt emacsclient options in doc
Michael Albinus [Thu, 13 Jun 2024 07:29:44 +0000 (09:29 +0200)]
Adapt emacsclient options in doc

* doc/emacs/misc.texi (emacsclient Options):
* doc/man/emacsclient.1: Adapt option list.

21 months agoFix removal of file locks on MS-Windows 9X
Eli Zaretskii [Thu, 13 Jun 2024 07:24:21 +0000 (10:24 +0300)]
Fix removal of file locks on MS-Windows 9X

A new Windows-specific function for validating process ID
is introduced that does TRT with possibly negative PID
values returned by 'getpid' on Windows 9X and also with
values larger than INT_MAX, since PID on Windows is
actually an unsigned 32-bit value.
* src/w32proc.c (w32_valid_process_id): New function.
* src/w32common.h (VALID_PROCESS_ID): Define for WINDOWSNT.
* src/filelock.c [WINDOWSNT]: Include w32common.h.  (Bug#71477)

21 months agoCorrectly define `select' binding on Android
Po Lu [Thu, 13 Jun 2024 02:46:59 +0000 (10:46 +0800)]
Correctly define `select' binding on Android

* lisp/term/android-win.el (input-decode-map): Cease binding
select in the initial frame's input-decode-map.

* src/androidterm.c (android_term_init): Binding select in the
freshly created kboard.
(syms_of_androidterm) <Qselect, Qreturn>: New symbols.

21 months agoHighlight the suffix in *Completions* buffer in 'basic' style too
Dmitry Gutov [Wed, 12 Jun 2024 21:46:00 +0000 (00:46 +0300)]
Highlight the suffix in *Completions* buffer in 'basic' style too

* lisp/minibuffer.el (completion-basic-all-completions):
Make sure to highlight the suffix as well (bug#71419).

21 months agoRelease ERC 5.6
F. Jason Park [Thu, 9 Nov 2023 00:45:37 +0000 (16:45 -0800)]
Release ERC 5.6

* lisp/erc/erc.el: Change Version header from 5.6-git to 5.6.  A
`customize-package-emacs-version-alist' mapping for ERC 5.6 to Emacs
30.1 was already added when moving from 5.5 to 5.6-git.  The ERCVER
variable in doc/misc/erc.texi was likewise updated at that time.
Going forward, such changes will continue to happen preemptively, on
the flip side of each release.
(erc-version): Change version from 5.6-git to 5.6.

21 months ago; Amend some doc strings in ERC
F. Jason Park [Tue, 11 Jun 2024 04:56:02 +0000 (21:56 -0700)]
; Amend some doc strings in ERC

* lisp/erc/erc-backend.el (define-erc-response-handler): Mention
important distinction between aliases for handlers and hooks, and note
expected type for the latter.
* lisp/erc/erc.el (erc--define-channel-user-status-compat-getter):
Mention that these accessors are not inlined like those generated by
`cl-defstruct'.

21 months ago; Mention new modes in the Emacs user manual
Eli Zaretskii [Wed, 12 Jun 2024 18:25:41 +0000 (21:25 +0300)]
; Mention new modes in the Emacs user manual

* etc/NEWS: Mark new modes as documented.
* doc/emacs/programs.texi (Program Modes): Add PHP.  (Bug#71380)
Add other new modes.

21 months agoAdd php-ts-mode
Vincenzo Pupillo [Fri, 7 Jun 2024 10:39:03 +0000 (12:39 +0200)]
Add php-ts-mode

* etc/NEWS: Mention the new mode.
* lisp/progmodes/php-ts-mode.el: New file.  (Bug#71380)

21 months agoStart of a fix for bug#71477
Paul Eggert [Wed, 12 Jun 2024 15:42:24 +0000 (08:42 -0700)]
Start of a fix for bug#71477

* src/filelock.c (integer_prefixed): New static function.
(VALID_PROCESS_ID): New macro.
(current_lock_owner): Use them to allow negative process IDs
on some Microsoft platforms.

21 months agoFix misspelled symbols in artist.el
Stefan Kangas [Wed, 12 Jun 2024 16:17:13 +0000 (18:17 +0200)]
Fix misspelled symbols in artist.el

* lisp/textmodes/artist.el (artist-key-undraw-continuously)
(artist-key-draw-continuously)
(artist-key-do-continuously-continuously)
(artist-key-do-continuously-poly)
(artist-key-do-continuously-1point)
(artist-key-do-continuously-2points)
(artist-key-do-continuously-common)
(artist-key-set-point-continuously)
(artist-mouse-draw-continuously): Rename functions to fix misspelling of
"continuously".  Leave old function names as obsolete aliases and update
all callers.
(artist-mt, artist-go-get-undraw-fn, artist-go-get-interval-fn)
(artist-go-get-fill-pred, artist-go-get-fill-fn)
(artist-key-undraw-common, artist-key-draw-common)
(artist-key-do-continously-common, artist-key-set-point-common)
(artist-down-mouse-1): Rename symbol to 'artist-do-continuously' to fix
misspelling of "continuously".  Continue supporting the old symbol for
backwards-compatibility.

21 months ago; * lisp/menu-bar.el (kill-this-buffer): Another doc fix (bug#71510).
Eli Zaretskii [Wed, 12 Jun 2024 12:21:27 +0000 (15:21 +0300)]
; * lisp/menu-bar.el (kill-this-buffer): Another doc fix (bug#71510).

21 months ago; * etc/NEWS: Add doc markup for char-to-name
Robert Pluim [Tue, 11 Jun 2024 16:35:46 +0000 (18:35 +0200)]
; * etc/NEWS: Add doc markup for char-to-name

21 months agoSupport --no-window-system option in emacsclient
Eli Zaretskii [Wed, 12 Jun 2024 11:10:32 +0000 (14:10 +0300)]
Support --no-window-system option in emacsclient

* lib-src/emacsclient.c (print_help_and_exit, longopts): Add
'--no-window-system' alias for -t.  (Bug#71509)

21 months ago; * lisp/menu-bar.el (kill-this-buffer): Doc fix (bug#71510).
Eli Zaretskii [Wed, 12 Jun 2024 10:53:19 +0000 (13:53 +0300)]
; * lisp/menu-bar.el (kill-this-buffer): Doc fix (bug#71510).

21 months agoFix tramp-compat-auth-info-password
Michael Albinus [Wed, 12 Jun 2024 10:46:10 +0000 (12:46 +0200)]
Fix tramp-compat-auth-info-password

* lisp/net/tramp-compat.el (tramp-compat-auth-info-password):
Use original function only for Emacs 30+.

21 months agoRestore omitted dependency
Po Lu [Wed, 12 Jun 2024 09:02:07 +0000 (17:02 +0800)]
Restore omitted dependency

* java/Makefile.in (install_temp): Depend on
$(libsrc)/asset-directory-tool.

21 months agoMerge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Eli Zaretskii [Wed, 12 Jun 2024 08:48:58 +0000 (11:48 +0300)]
Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs

21 months agoFix info/DIR generation broken by update to Org manual
Eli Zaretskii [Wed, 12 Jun 2024 08:46:36 +0000 (11:46 +0300)]
Fix info/DIR generation broken by update to Org manual

* build-aux/make-info-dir: Adapt to latest changes in Org manual's
markup.

21 months agoMerge remote-tracking branch 'savannah/master' into master-android-1
Po Lu [Wed, 12 Jun 2024 08:45:47 +0000 (16:45 +0800)]
Merge remote-tracking branch 'savannah/master' into master-android-1

21 months agoRestore functionality on Android 2.2
Po Lu [Wed, 12 Jun 2024 08:44:21 +0000 (16:44 +0800)]
Restore functionality on Android 2.2

* java/Makefile.in (install_temp): Do not compress
directory-tree and generate such files in a special format that
stores file sizes.

* lib-src/asset-directory-tool.c (struct directory_tree): New
field st_size.
(need_file_size): New variable.
(main_1, main_2, main): Write file sizes before sibling offsets
if `--api-8' is specified.

* src/android-asset.h (struct android_asset_manager): New field
open.
(struct android_asset): New field name.
(AAssetManager_fromJava): Load AssetManager#open.
(AAssetManager_open): If a directory tree has already been
loaded, search for a matching asset and load its size thence, to
avoid the requirement of an AssetFileDescriptor.
(AAsset_close): Don't assume asset->fd exists.  Release
asset->name.
(AAsset_getLength): Likewise.
(android_asset_create_stream): If asset->name exists, call
AssetManager#open, in order to open compressed files.

* src/androidvfs.c (OLD_ANDROID_ASSETS): Define to 1 on API 8.
(android_extract_long, android_scan_directory_tree): Mark
arguments as const.  Adjust offsets when OLD_ANDROID_ASSETS.
(android_is_directory, android_init_assets, android_afs_readdir):
Likewise.

* src/lread.c (lread_fstat): Define to sys_fstat, not fstat.